<template>
  <div>
    <!-- 头部标签,专门放导航的 -->
    <div id="head">
      <router-link to="/index" class="nav">首页</router-link>
      <router-link :to="{ path: '/book' }" class="nav">book</router-link>
    </div>
    <router-view></router-view>
  </div>
</template>


<script setup >
// router 路由 url路径 和页面  进行关联起来
// http://192.168.134.3/user    user
</script>

<style scoped>
.nav {
  color: #ccc;
  padding: 10px;
  text-decoration: none;
  transition: all 0.8s;
}
.nav:hover{
  color: aqua;
  border-bottom: 1px solid aqua;
}

</style>